import request from '@/utils/request'

export function registerAPI (data) {
  return request.post('/index/reg', data)
}

export function loginAPI (data) {
  return request.post('/index/login', data)
}

export function getUserInfoAPI () {
  return request.get('user/getUserInfo')
}

export function updataImgAPI (data) {
  return request.post('/user/update', data)
}

// 我的点赞
export function myDianzanApi (data) {
  return request.get('/user/userDataList', { params: data })
}

export function likeAndCollApi (data) {
  return request({
    method: 'get',
    url: '/user/userDataHandle',
    params: data
  })
}

// 我的文章
export function myArticleApi (data) {
  return request.get('/user/myArticle', { params: data })
}
